home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-02 / svgabg31.zip / TWK256.INC < prev    next >
Text File  |  1991-09-28  |  993b  |  42 lines

  1. (************************************************)
  2. (*                         *)
  3. (*      Tweaked 256 BGI driver defines    *)
  4. (*        Copyright (c) 1991        *)
  5. (*        Jordan Hargraphix Software        *)
  6. (*                        *)
  7. (************************************************)
  8.  
  9. type DacPalette256 = array[0..255] of array[0..2] of Byte;
  10.  
  11. (* These are the currently supported modes *)
  12. const
  13.   TWK320x400x256    = 0;
  14.   TWK320x480x256    = 1;
  15.   TWK360x480x256    = 2;
  16.   TWK376x564x256    = 3;
  17.   TWK400x564x256    = 4;
  18.   TWK400x600x256    = 5;
  19.  
  20.   XNOR_PUT        = 5;
  21.   NOR_PUT        = 6;
  22.   NAND_PUT        = 7;
  23.   TRANS_COPY_PUT    = 8;    (* Doesn't work on 16-color systems *)
  24.  
  25. (* Setvgapalette sets the entire 256 color palette *)
  26. (* PalBuf contains RGB values for all 256 colors   *)
  27. (* R,G,B values range from 0 to 63               *)
  28. procedure SetVGAPalette256(PalBuf : DacPalette256);
  29. var
  30.   Reg : Registers;
  31.  
  32. begin
  33.   reg.ax := $1012;
  34.   reg.bx := 0;
  35.   reg.cx := 256;
  36.   reg.es := Seg(PalBuf);
  37.   reg.dx := Ofs(PalBuf);
  38.   intr($10,reg);
  39. end;
  40.  
  41.  
  42.